set fileencodings=utf-8,cp936,big5,latin1
set encoding=utf-8
set fileencoding=utf-8
filetype plugin indent on
colorscheme desert
syntax on

set background=dark

set fileformat=unix

set foldlevel=100  " 启动vim时不要自动折叠代码

set ruler " the column number of the cursor
set showcmd "显示命令

"set display=lastline        " 长行不能完全显示时显示当前屏幕能显示的部分
                             " 默认值为空，长行不能完全显示时显示 @

" Use the cool tab complete menu
"set wildmenu "自动补全命令时候使用菜单式匹配列表
"set wildmenu

" Try to show at least three lines and two columns of context when scrolling
"set scrolloff=3
"set sidescrolloff=2

" Show full tags when doing search completion
set showfulltag

" Wrap on these
set whichwrap+=<,>,[,]

" Map <F8> key to open or close the taglist window
nnoremap <silent> <F8> :Tlist<CR>

" Map <F9> key to open or close the NERDTree window
nnoremap <silent> <F9> :NERDTreeToggle<CR>

" MiniBufExpl key mapping:  Switch buffers using <C-TAB> and <C-S-TAB>
"let g:miniBufExplMapCTabSwitchBufs = 1

"NERDTree options
let NERDTreeIgnore=['lost+found', '\.pyc$', '\.orig$', '\~$']
let NERDTreeWinSize=22

" Highlight end of line whitespace.
highlight WhitespaceEOL ctermbg=red guibg=red
match WhitespaceEOL /\s\+$/
